1. Field of the Invention
The invention relates to a cache technique, and particularly relates to a tag memory and a cache system with an automating tag comparison mechanism and a cache method thereof.
2. Description of Related Art
In a computer system, a processor may use a cache memory to improve a data access performance thereof to thereby increase an overall performance of the computer system. The cache memory including an area storing tags and an area storing data. Tags are accessed and compared to determine whether the current cache memory stores required data. In general, as a static random access memory (SRAM) has a fast accessing speed, SRAM is commonly used to store tags. When the capacity of the cache memory is increased to facilitate the overall performance of the computer system, a storage of tags is increased as well. However, increasing the capacity (or increasing the number of SRAM) of SRAM to store a large number of tags may significantly increase the hardware cost. Thus, a memory device, such as dynamic random access memory (DRAM), which is of a higher capacity and lower cost may be used to store tags.
For a memory such as DRAM, it is required to wait a period of time to sequentially output the tags to be compared after receiving a read command and an address, and the tags to be compared are unable to be output at the same time, making it unable to perform a parallel comparison for the tags to be compared. Therefore, the time for tag comparison is significantly increased, and the overall performance of the computer system is compromised.